#ifndef __perso_H__
#define __perso_H__

struct
{
    int index;
    int lasttime;
    int delay;
    SDL_Surface* image;
    int width;
    int offset;
    int margin;
} typedef Animation;

Animation* createAnimation(SDL_Surface* image, int width, int offset, int margin);
void freeAnimation(Animation* anim);
void setAnimationSpeed(Animation* anim, unsigned int speed);
void drawAnimation(Animation* anim, SDL_Surface* screen, SDL_Rect* position);
int perso(int *personnage);

#endif